<template>
	<view class="content">
		<image class="logo" src="/static/logo.png"></image>
		<view class="text-area">
			<text class="title">{{title}}</text>
		</view>
		<view>
			<view>{{number+1}}</view>
			<view>{{ok ? 'YES' : 'NO'}}</view>
			<view>{{message.split('').reverse().join('')}}</view>
		</view>
		
		<view v-for="item in arr" style="color: #ff0000;">
			{{item}}
		</view>
		
		<view v-for="(item,index) in 4" style="color: #00ff00;">
			<view :class="'list-' + index%2">
				{{index%2}}
			</view>
		</view>
		
		<view v-for="(value,name,index) in Object">
			{{index}}---{{name}}---{{value}}
		</view>
		
		<view v-for="item in arr" :key="item.id">
			<view style="color: #0000ff;">
				{{item.id}} : {{item.name}}
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title:'Hello',
				number:1,
				ok:true,
				message:'Hello Vue!',
				arr:[
					{id:1,name:'uni-app'},
					{id:2,name:'HTML'},
					{id:3,name:'小郭 '},
					{id:4,name:'小张'}
				],
				Object:{
					title:'How to do lists in Vue',
					author:'Jane Doe',
					publisheaAt:'2020-04-10'
				}
			}
		},
		methods: {
			handleClick(param1,param2,event){
				console.log("参数1 ",param1)
			},
			handleButton(msg,event){
				console.log("接受的信息",msg)
			}
		}
	}
</script>

<style>
.logo {
		height: 200rpx;
		width: 200rpx;
		margin-top: 100rpx;
		margin-left: auto;
		margin-right: auto;
		margin-bottom: 50rpx;
	}
.content {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
	}
.title {
		font-size: 36rpx;
		color: #8f8f94;
	}
/* .logos {
			height: 200rpx;
			width: 200rpx;
			margin-top: 100rpx;
			margin-left: auto;
			margin-right: auto;
			margin-bottom: 50rpx;
			background-color: aqua;
		} */
</style>
